import React from 'react'
import {
    useSelector
} from "react-redux"
import {mainRouter} from "../router/RouterConfig"

function Header() {
    //获取仓库里的active
    const active = useSelector((state)=>{
        return state.reducer.active
    })
    
    return (
        <div>
            {
                mainRouter[active].title
            }
        </div>
    )
}

export default Header
